from shapes import*
from pat import *

world = TurtleWorld()
ark = Turtle()
ark.delay = 0

def showmenu():
    print "1: Square         \t\t11: Star"
    print "2: Rectangle      \t\t12: Line"
    print "3: Arc            \t\t13: Move"
    print "4: Equilateral_tri\t\t14: Sword"
    print "5: Right_tri      \t\t15: Stars"
    print "6: Sss_tri        \t\t16: Bomb"
    print "7: Tri            \t\t17: Star of death"
    print "8: Para           "
    print "9: Rhom           "          
    print "10: Poly          \t\t20: Exit"
    answer = raw_input("Choose a number ")
    return answer
    
def drawshape(t, option):
    if option == "1":
        size = raw_input("How large ")
        size = float(size)
        square(t, size)
    elif option == "2":
        length = input("how long ")
        height4 = input("how tall ")
        rect(t, length, height)
    elif option == "3":
        radius = input("how big ")
        angle = input("how tall ")
        arc(t, radius, angle)
    elif option == "4":
        size = input("how big ")
        rotation = input("how tall ")
        equilateral_tri(t, size, rotation)
    elif option == "5":
        length = input("how long ")
        height = input("how tall ")
        right_tri(t, length, height)
    elif option == "6":
        side = input("side length? ")
        size1 = input("side length? ")
        sss_tri(t, side, side1.side2)
    elif option == "7":
        side = input("side length? ")
        tri(t, side)
    elif option == "8":
        width = input("how wide ")
        height = input("how tall ")
        angle = input("how big of an angle ")
        para(t, width, height, angle)
    elif option == "9":
        size = input("how big ")
        angle = input("how big of an angle ")
        rhom(t, size, angle)
    elif option == "10":
        sides = input("how many sides ")
        size = input("how big ")
        poly(t, sides, size)
    elif option == "11":
        points = input("how many points ")
        size = input("how big ")
        star(t, points, size)
    elif option == "12":
        x = input("chose X ")
        y = input("chose y ")
        line(t, x, y)
    elif option == "13":
        x = input("chose X ")
        y = input("chose y ")
        move(t, x, y)
    elif option == "14":
        sword(t)
    elif option == "15":
        stars(t)
    elif option == "16":
        bomb(t)
    elif option == "17":
        star_of_death(t)
    elif option == "18":
        sqspyrl(t, 3000, 1000, 10)
    else:
        print "Unknow CMD"

def run():
    while True:
        opt = showmenu()
        if opt == "20":
            wait_for_user()
            exit()
        drawshape(ark, opt)

run()